/*
 * Copyright (C) 2025 Tsingteng MicroSystem
 *
 * Licensed under the Apache License, Version 2.0 (the "License");
 * you may not use this file except in compliance with the License.
 * You may obtain a copy of the License at
 *
 * http://www.apache.org/licenses/LICENSE-2.0
 *
 * Unless required by applicable law or agreed to in writing, software
 * distributed under the License is distributed on an "AS IS" BASIS,
 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
 * See the License for the specific language governing permissions and
 * limitations under the License.
 */
#ifndef _HCI_CMD_H_
#define _HCI_CMD_H_
#include "nfa_base.h"

#define HCI_CMD_TIMEOUT_MS 2000

typedef struct {
    uint16_t len; // dat长度
    // 以下格式参考set param格式，请勿调整顺序格式
    uint8_t index;
    uint8_t dat[0];
} tHCI_PARAM;

tNCI_STATUS hci_cmd_any_set_param(uint8_t pipe, const tHCI_PARAM *param);
tNCI_STATUS hci_cmd_any_get_param(uint8_t pipe, uint8_t param_index, tHCI_PARAM **param);
tNCI_STATUS hci_cmd_any_open_pipe(uint8_t pipe);
tNCI_STATUS hci_cmd_any_close_pipe(uint8_t pipe);
tNCI_STATUS hci_cmd_adm_create_pipe(uint8_t src_gate, uint8_t dest_host, uint8_t dest_gate, uint8_t *pipe);
tNCI_STATUS hci_cmd_adm_delete_pipe(uint8_t pipe);
tNCI_STATUS hci_cmd_adm_clear_all_pipe(void);

#endif
